package noname;

import java.awt.*;
import javax.swing.JComponent;

public class MainView extends javax.swing.JFrame {
    
    private Controller controller;
    
    public MainView(Controller controller) {
        this.controller = controller;
        initComponents();
        this.setLayout(new GridLayout());
        pnlMainView.setLayout(new GridLayout());
        //pnlMultimedia.setLayout(new GridLayout());
        this.setSize(1024, 768);
    }
    
    public void setMainView(JComponent compontent) {
        pnlMainView.add(compontent);
    }
    
    public JComponent getMultimediaPanel()
    {
        return pnlMultimedia;
    }
    
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        pnlMainView = new javax.swing.JPanel();
        pnlMultimedia = new javax.swing.JPanel();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);

        pnlMainView.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));

        javax.swing.GroupLayout pnlMainViewLayout = new javax.swing.GroupLayout(pnlMainView);
        pnlMainView.setLayout(pnlMainViewLayout);
        pnlMainViewLayout.setHorizontalGroup(
            pnlMainViewLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 320, Short.MAX_VALUE)
        );
        pnlMainViewLayout.setVerticalGroup(
            pnlMainViewLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 443, Short.MAX_VALUE)
        );

        pnlMultimedia.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(51, 102, 255)));

        javax.swing.GroupLayout pnlMultimediaLayout = new javax.swing.GroupLayout(pnlMultimedia);
        pnlMultimedia.setLayout(pnlMultimediaLayout);
        pnlMultimediaLayout.setHorizontalGroup(
            pnlMultimediaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 185, Short.MAX_VALUE)
        );
        pnlMultimediaLayout.setVerticalGroup(
            pnlMultimediaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 0, Short.MAX_VALUE)
        );

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(pnlMainView, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(pnlMultimedia, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(pnlMultimedia, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(pnlMainView, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JPanel pnlMainView;
    private javax.swing.JPanel pnlMultimedia;
    // End of variables declaration//GEN-END:variables
}
